package cn.ncupyh.soft;

public class Phone {
//    //    创建一个数组存储三个手机对象
////    手机属性:品牌,价格,颜色
//    要求:计算出三部手机的平均价格

//    属性:
    private String brand;
    private double price;
    private String color;

    //方法构造
    public Phone() {
    }

    public Phone(String brand, double price, String color) {
        this.brand = brand;
        this.price = price;
        this.color = color;
    }

//    set/get
    public String getBrand() {
        return brand;
    }

    public void setBrand(String brand) {
        this.brand = brand;
    }

    public double getPrice() {
        return price;
    }

    public void setPrice(double price) {
        this.price = price;
    }

    public String getColor() {
        return color;
    }

    public void setColor(String color) {
        this.color = color;
    }

}

